<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE topic
  PUBLIC "-//OASIS//DTD DITA Composite//EN" "ditabase.dtd">
<topic id="topic1"><title id="dh20941">DROP SEQUENCE</title><body><p id="sql_command_desc">Removes a sequence.</p><section id="section2"><title>Synopsis</title><codeblock id="sql_command_synopsis">DROP SEQUENCE [IF EXISTS] <varname>name</varname> [, ...] [CASCADE | RESTRICT]</codeblock></section><section id="section3"><title>Description</title><p><codeph>DROP SEQUENCE</codeph> removes a sequence generator table. You must own the sequence to
        drop it (or be a superuser).</p></section><section id="section4"><title>Parameters</title><parml><plentry><pt>IF EXISTS</pt><pd>Do not throw an error if the sequence does not exist. A notice is
issued in this case.</pd></plentry><plentry><pt><varname>name</varname></pt><pd>The name (optionally schema-qualified) of the sequence to remove.</pd></plentry><plentry><pt>CASCADE</pt><pd>Automatically drop objects that depend on the sequence.</pd></plentry><plentry><pt>RESTRICT</pt><pd>Refuse to drop the sequence if any objects depend on it. This is
the default. </pd></plentry></parml></section><section id="section5"><title>Examples</title><p>Remove the sequence <codeph>myserial</codeph>: </p><codeblock>DROP SEQUENCE myserial;</codeblock></section><section id="section6"><title>Compatibility</title><p><codeph>DROP SEQUENCE</codeph> is fully conforming with the SQL standard,
except that the standard only allows one sequence to be dropped per command.
Also, the <codeph>IF EXISTS</codeph> option is a Greenplum Database extension.</p></section><section id="section7"><title>See Also</title><p><codeph><xref href="ALTER_SEQUENCE.xml#topic1" type="topic" format="dita"/></codeph>,
            <codeph><xref href="CREATE_SEQUENCE.xml#topic1" type="topic" format="dita"
        /></codeph></p></section></body></topic>
